﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Master/MasterPage.master" AutoEventWireup="true"
    CodeFile="StageConfig_Dev_M.aspx.cs" Inherits="StageConfig_Dev_M" %>

<asp:Content ID="Content2" ContentPlaceHolderID="script" runat="Server">
    <style type="text/css">
       
    </style>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="body" runat="Server">
    <div class="container">
        <div class="titlebg">
            <div class="title">
                开发大纲项目期与明源项目期关联设置</div>
        </div>
        <div class="content">

    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <table style="width: 500px; margin-left: 30px; margin-top: 20px;">
                <tr>
                    <td colspan="2" style="padding-top: 10px; padding-bottom: 10px;">
                        请选择项目：<asp:DropDownList ID="ddlProjectList" runat="server" Width="160px" DataSourceID="ODSPData"
                            DataTextField="ProjectName" DataValueField="Id" AutoPostBack="True" 
                            onselectedindexchanged="ddlProjectList_SelectedIndexChanged">
                        </asp:DropDownList>
                       
                        <HR style="FILTER: alpha(opacity=100,finishopacity=0,style=3); margin-top:20px;" width="80%" SIZE=3 >
                    </td>
                </tr>
                <tr>
                    <td rowspan="3">
                    所属分期：<br/><br/>
                        <asp:ListBox ID="lb_RelationList" runat="server" DataSourceID="ODSEList" DataTextField="StageName"
                            DataValueField="Id" Height="580px" Width="300px" OnSelectedIndexChanged="lb_RelationList_SelectedIndexChanged"
                            AutoPostBack="True" style=" margin-right:20px;"></asp:ListBox>
                    </td>
                    <td valign="top">
                    可关联明源分期：<br/><br/>
                        <asp:ListBox ID="lb_NoHaveBeRelationList" runat="server" DataSourceID="ODSNRList"
                            DataTextField="Name" DataValueField="Id" Height="250px" Width="300px"></asp:ListBox>
                    </td>
                </tr>
                <tr>
                    <td>
                        <table width="100%">
                            <tr>
                                <td>
                                    <asp:Button ID="btnAdd" runat="server" Text="添加" OnClick="btnAdd_Click" />
                                </td>
                                <td align="center">
                                    <asp:Button ID="btnDel" runat="server" Text="删除" OnClick="btnDel_Click" />
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
                <tr>
                    <td valign="bottom">
                    已关联明源分期：<br/><br/>
                        <asp:ListBox ID="lb_HaveBeRelationList" runat="server" Height="250px" Width="300px"
                            DataSourceID="ODSRList" DataTextField="Name" DataValueField="Id"></asp:ListBox>
                    </td>
                </tr>
            </table>
            <asp:ObjectDataSource ID="ODSEList" runat="server" SelectMethod="GetProjectStageList"
                TypeName="PKURG.CostSplit.Business.Project" 
                OldValuesParameterFormatString="original_{0}">
                <SelectParameters>
                    <asp:ControlParameter ControlID="ddlProjectList" Name="projectStageId" PropertyName="SelectedValue"
                        Type="String" />
                </SelectParameters>
            </asp:ObjectDataSource>
            <asp:ObjectDataSource ID="ODSRList" runat="server" SelectMethod="GetRelationList"
                TypeName="PKURG.CostSplit.Business.Relation" 
                OldValuesParameterFormatString="original_{0}">
                <SelectParameters>
                    <asp:ControlParameter ControlID="lb_RelationList" Name="id" PropertyName="SelectedValue"
                        Type="String" />
                    <asp:Parameter DefaultValue="4" Name="rType" Type="Int32" />
                </SelectParameters>
            </asp:ObjectDataSource>
            <asp:ObjectDataSource ID="ODSNRList" runat="server" SelectMethod="GetNoRelationList"
                TypeName="PKURG.CostSplit.Business.Relation" 
                OldValuesParameterFormatString="original_{0}">
                <SelectParameters>
                    <asp:ControlParameter ControlID="lb_RelationList" Name="id" PropertyName="SelectedValue"
                        Type="String" />
                    <asp:Parameter DefaultValue="4" Name="rType" Type="Int32" />
                </SelectParameters>
            </asp:ObjectDataSource>
            <asp:ObjectDataSource ID="ODSPData" runat="server" SelectMethod="GetAll"
                TypeName="PKURG.CostSplit.Services.VDevProjectService" 
                OldValuesParameterFormatString="original_{0}"></asp:ObjectDataSource>
        </ContentTemplate>
    </asp:UpdatePanel>
            </div>
        </div>
</asp:Content>
